Link to home
Start Free TrialLog in
Avatar of tjonas
tjonas

asked on

PB, an Updateable Stored Proc, and a Timestamp

I am building an application with PB V6.5 and Sybase V11.5.  I a using the PFC and supplying all of the IUD logic to the SQL Preview event via the Stored Procedure Utility.  I need to compare timestamps in my update procedures; however, PowerBuilder has no concept of Varbinary.   I can pass the timestamp down as a string but when it comes time to pass the timestamp back up to the update proc I'm at a loss as to how to get it back to its original varbinary format.  Converting it on the client and passing it back is not an option.  Any ideas?
Avatar of ajith_29
ajith_29

Try the option of converting as string to input to the client end and then pass back from the client side to the sever using convert function as string giving max as varchar(255).Then when passed back it can covert to the required varbinary.The reason is varbinary max can only be 255.This will solve your problem.
Regards Ajith
Avatar of tjonas

ASKER

Could you be more specific.  What should my variable declaration be in the stored procedure that accepts the value back from Powerbuilder?  What should the string size be in the datasource declaration of the Powerbuilder datawindow.  I've tried several permutations of your suggestion but the tsequal function still does not recognize the converted value as the same timestamp as the record's timestamp.
ASKER CERTIFIED SOLUTION
Avatar of ajith_29
ajith_29

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial