• Welcome to SQLitening Support Forum.
 

News:

Welcome to the SQLitening support forums!

Main Menu
Menu

Show posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Show posts Menu

Messages - cyberazor

#1
Setting locale may affect other softwares, please take it into consideration.

For example, Total Commander cannot display Chinese correctly on its menu after changing of locale.
#2
For rarely introductions and documents are written in Chinese, I want to post some articles on my Chinese blog for such a nice project, with some .Net examples and attentions for non-English user.

So am I permitted to show and analyse the source code of SQLitening by reference?
#3
I thought the only difference among our computers is system locale, so I changed it from Chinese to English on server-side in control panel.

Now it works. I've learned a lot besides the question. Thank you cj! Thank you all!
#4
Quote from: cj38,011  CLIENT.ZIP
Error still...
#5
Quote from: cjIf sample.db3 contained some nul characters some strange results could occur.
Please try downloading my sample.zip which contains sample.db3..
Still break at row 74..
#6
My log start with:
Quote140310091952 Admn Strt ==========<[ Start Server 1.60.5.0 ]>==========
140310091952 Admn Flgs TrimLogManually=No
140310091952 Admn Flgs LogConnDcon=Yes
140310091952 Admn Flgs LogInvalidInMessage=Yes
140310091952 Admn Flgs CreateDatabaseAllowed=Yes
140310091952 Admn Data MaxChunkSize=500
140310091952 Admn Data MaxConnections=0
140310091952 Admn Data ConnectionTimeout=30
140310091952 Admn FACT Loaded
140310091952 Host LocalHost(127.0.0.1)  Socket=440  Port=926  ServiceNameSuffix=
140310091952 Host 10.179.25.3(10.179.25.3)  Socket=460  Port=926  ServiceNameSuffix=

QuoteAdded slDisconnect after LOOP, but this is not a critical error.
Problem remains after added slDisconnect.

QuoteNot sure if you have access to another machine to check if a router or network card issue?
I'll try, but I don't think it will affect.
Because data stream is received and unzipped correctly by client, but SQLiteNextRow cannot retrieve a right position of next row as Dword.
#7
Quote from: cjIf LIMIT 1 is removed do all 10,000 rows display correctly, now?
No, error still occured on row 74.
#8
Yes, the result is
3COM 00100283 Etherlink III Lan + Modem Cable (for 3c562) XXX PC INT -STAND. NETWORK MODULE 3365
RowCount 1


I've revised your code to:
#INCLUDE "inc\sqlitening.inc"
#INCLUDE "win32api.inc"
$OutputFile="results.txt":$Server="10.179.25.3":%PortNumber= 926
$SelectStatement = "select * from parts limit 1"
FUNCTION PBMAIN () AS LONG
  LOCAL COLUMN,LastColumn AS LONG,sData AS STRING, RowCount,hFile AS LONG
  hFile = FREEFILE
  OPEN $OutputFile FOR OUTPUT AS #hFile
  slConnect $Server,%PortNumber
  slOpen "sample.db3","C"
  slsel $SelectStatement
  LastColumn = slGetColumnCount
  DO WHILE slGetRow
    INCR RowCount
    sData = ""
    FOR COLUMN  = 1 TO LastColumn
      sData = sData + slf(COLUMN) + $TAB
    NEXT
    sData = LEFT$(sData,(LEN(sData)-1))
    PRINT #hFile, sData
  LOOP
  PRINT #hFile,"RowCount ";FORMAT$(RowCount,"#,")
  CLOSE #hFile:SLEEP 1000
  LOCAL zText AS ASCIIZ * 256
  zText = $OutputFile
  ShellExecute (%NULL, "OPEN", zText, BYVAL %NULL, CURDIR$, %SW_SHOWNORMAL)
END FUNCTION

and compiled with PB 10.03.

All changes are:
Quote#INCLUDE "inc\sqlitening.inc"
$OutputFile="results.txt":$Server="10.179.25.3":%PortNumber= 926
#9
Quote from: cjYou are using just PowerBASIC and not .NET, right?
I tested on PowerBasic, VB6 and VB.Net. All of them have the same result.
#10
Two of these files' size mismatched, and almost all time are different:
Quote2012/07/22  02:30         1,346,560 sample.db3

2012/06/11  19:05           599,419 SQLite3.dll
2012/11/18  10:32            91,648 SQLitening.dll
2012/07/22  02:30            30,208 SQLiteningAuxRuts.dll
2012/12/06  11:28            54,784 SQLiteningClient.dll
2012/08/02  14:30            11,776 SQLiteningS.dll
2012/08/02  14:30            15,360 SQLiteningU.dll
2012/07/22  02:30            74,240 SQLiteningZlib.dll

2012/12/06  11:30           124,928 SQLiteningServer.exe
2012/07/22  02:30            93,696 SQLiteningServerAdmin.exe
Am I downloaded a wrong package? All above files are original version from "sqlitening_160_5.zip". I wasn't recompiled anyone.
#11
Nothing changed.  :(
I downloaded the "sqlitening_160_5.zip" again from:
http://www.sqlitening.com/support/index.php?topic=3560.0
And then on my server machine:
1) Stop SQLitening server.
2) Uninstall SQLitening server.
3) Delete all files except "SQLiteningServer.cfg" in "SQLitening\bin\" folder of server.
4) Reboot system of server.
5) Unpack "sqlitening_160_5.zip" to the same path "SQLitening\bin\" (also except "SQLiteningServer.cfg").
6) Deploy test program to server which is aimed at localhost, so that test and SQLitening are using the same dlls.
6) Install SQLitening server.
7) Start SQLitening server.
#12
Thank you cj, I've find out the problem, the length of data row is miscalculated on client side, so that SQLiteningClient.dll cannot update current row position correctly.

Like 1st row of "SELECT * FROM sqlite_master;":
Server-side:
FUNCTION BuildRowDataChunk()
    '...
    ' Add the row to the rows array
    lsaRows(llRowIX) = MKL$(llRowLength) & lsRow
    '...
END FUNCTION

llRowLength= CVL(MKL$(llRowLength))= 233

But  on client:
FUNCTION SQLiteNextRow ALIAS "SQLiteNextRow" ()
    '...
    ' Bump to next
    lhCurRowPos = lhCurRowPos + CVDWD(tsaSets(llSetIX), lhCurRowPos) + 4
    '...
END FUNCTION

CVDWD(tsaSets(llSetIX), lhCurRowPos) become to 63 (which is seemed the ASCII of "?").

As source says:
'   Row data chunk in array format:
'        1 -   4 = Set number as Long.
'        5 -   8 = Position of next row as Dword.
'        9 -  12 = Length of row data chunk.
'       13 -   R = Row data chunk
'      R+1 - R+4 = Position next row data chunk as Dword, zero if none

I've checked 5-8 of RDC both sever and client side, but found nothing different.
So I'm so confused for which the dword changed. :(
#13
Hi cj,

Both my server and client's system are windows 7 32bit.
sample.db3 files on each computer are all the same.

Your test of "select * from parts limit 11" returns 11 rows correctly, but the error occurs at row 73 (just like the screenshot on Reply #11).
Error occurs not only in remote server but also in local host.
#14
By using LogIt() of SQLitening.bas, I tried to log lsRowDataChunk in SQLiteNextRow() of SQLiteningClient.dll, where I guess that slGetRow() affected, but nothing happened.
#15
Hi cj,

I tried your code in slF() but the errors still occured.
I guess slF() may not have problems because it works fine in local mode.

So is there any possibility that data are broken in slGetRow() or even slSel()?
IF tuFlags.AreRunningRemote THEN
    '...
ELSE
    '...
END IF

For I'm not good at PowerBasic, is there any way to trace data in such code?