Hard crash during SQL execution
Bart Pietercil
bart.pietercil at gmail.com
Sat Feb 10 10:05:03 CST 2007
Hi,
I'm relatively new to Valentina so consider the coming suggestions
with this in mind;
I don't know whether Valentina does automatic escaping of reserved
SQL characters.
What has happened to me is that (for a select query) the values
passed in the WHERE clause contain accents ('). They could lead to a
misinterpretation from the queryparser that might lead to an
execption (usually column not found). It could explain the random
behaviour of the crash (depending on the values passed)
Just my 5€.cents
HTH
Bart Pietercil
On 10-feb-07, at 16:47, Steve Albin wrote:
> My Windows user is complaining of hard crashes (bypassing the
> exception processing) of my app. I have sent him an app that has
> Valentina logging turned on and in the logs he is sending me, the
> crash seems to be coming after various SQL statements. Here are
> the last entries of two different logs.
>
> Database_SqlSelect_1...
> PARAM: instance = 27509744
> PARAM: inQuery = "Select issues.recid, issues.*,
> Perfs.nPerfRef, Types.cTypeName,
> Types.nSortOrd, Labels.cLabel, IssPerfs.nPerfId, perfs.nperfid,
> Types.nId, Labels.nid, IssPerfs.nIssueId
> From issues, issPerfs, perfs, Labels, Types
> Where perfs.nsessid = 303
> AND IssPerfs.nPerfId = perfs.nperfid
> AND Issues.cFormat = Types.nId
> AND Issues.nlabelId = Labels.nid
> and IssPerfs.nIssueId = Issues.nId
> ORDER BY Types.nSortOrd, Issues.dIssueDate, Issues.cTitleIdx "
> PARAM: inCursorLocation = 2
> PARAM: inCursorType = 1
> PARAM: inDirection = 2
>
>
> Database_SqlSelect_1...
> PARAM: instance = 27509912
> PARAM: inQuery = "Select distinct Players.nAxId,
> Players.nArtId, Artists.fullName,
> Ax.cAxAbbrev, Artists.FName, Artists.LName, Ax.cAxName,
> Ax.nId, Artists.nId, Ax.nAxSort,
> Artists.nameIdx, Players.nSessid
> from Players, Artists, Ax
> WHERE Players.nSessId = 5075
> AND Players.nAxId = Ax.nId
> AND Players.nArtId = Artists.nid
> AND Players.nAxId <> 4
> ORDER BY Ax.nAxSort, Artists.nameIdx, Players.nArtId"
> PARAM: inCursorLocation = 2
> PARAM: inCursorType = 1
> PARAM: inDirection = 2
>
> Since there is no return object listed in the log, am I safe to
> assume that something in the Valentina SQL is causing the crash?
>
> He has reindexed the database and run a diagnose which indicates no
> problems. I cannot get the Mac version to crash and when I run the
> program on Virtual PC, it will not crash. I'm thinking that maybe
> Virtual PC is not letting the program run fast enough to allow the
> timing issue that is causing the problem.
>
> Obviously, this SQL is syntactically ok since it works on the Mac
> version, but is there anything that looks suspicious in this that I
> could change to avoid the crash. I did have one instance of an SQL
> that had a field not listed in the select clause but listed in the
> order by clause and that caused a hard crash on the Mac until I
> fixed it.
>
> Steve
>
> --
> Steve Albin - Montclair, NJ
> http://www.jazzdiscography.com/
> http://www.steve-albin.com/
> _______________________________________________
> Valentina mailing list
> Valentina at lists.macserve.net
> http://lists.macserve.net/mailman/listinfo/valentina
More information about the Valentina
mailing list