Re: [U2] Friday type of question
LEN(@RECORD) is a sufficient answer to the underlying question. I had remembered LEN and couldn't recall the @RECORD. Thank you. David -Original Message- From: u2-users-boun...@listserver.u2ug.org [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Wjhonson Sent: Friday, August 31, 2012 4:49 PM To: u2-users@listserver.u2ug.org Subject: Re: [U2] Friday type of question In the DICT, in an I-descriptor you can specify LEN(@RECORD) If the record has zero length it's empty. -Original Message- From: Morelli, David W. dmore...@pacificu.edu To: U2 Users List u2-users@listserver.u2ug.org Sent: Fri, Aug 31, 2012 4:42 pm Subject: [U2] Friday type of question Is there an easy way to determine if a record is empty? I have a saved list of a thousand or more records that have record ID's that interfere with our Ellusian database. If they are truly empty, I can do house cleaning on them. If they contain any data, I have to do a different process. When I AE into a record I get :AE PERSON 2362 Top of 2362 in PERSON, 0 lines. So, it is really empty. I believe there must be a better way than handling every one of them, but I have been away from Unidata and forgotten everything. David Morelli Pacific University Oregon ___ U2-Users mailing list U2-Users@listserver.u2ug.org http://listserver.u2ug.org/mailman/listinfo/u2-users ___ U2-Users mailing list U2-Users@listserver.u2ug.org http://listserver.u2ug.org/mailman/listinfo/u2-users ___ U2-Users mailing list U2-Users@listserver.u2ug.org http://listserver.u2ug.org/mailman/listinfo/u2-users
[U2] Friday type of question
Is there an easy way to determine if a record is empty? I have a saved list of a thousand or more records that have record ID's that interfere with our Ellusian database. If they are truly empty, I can do house cleaning on them. If they contain any data, I have to do a different process. When I AE into a record I get :AE PERSON 2362 Top of 2362 in PERSON, 0 lines. So, it is really empty. I believe there must be a better way than handling every one of them, but I have been away from Unidata and forgotten everything. David Morelli Pacific University Oregon ___ U2-Users mailing list U2-Users@listserver.u2ug.org http://listserver.u2ug.org/mailman/listinfo/u2-users
Re: [U2] MS-SQL Question
Will your statements support something in the nature of : SELECT ... , a.PID , ... FROM ( SELECT ... , substring(colname ,charindex('|',colname)+1, charindex('|',colname, charindex('|',colname)+1) - charindex('|',colname) -1) as PID , ... FROM dbo.table ) a WHERE PID = Selection criteria David Morelli Pacific University -Original Message- From: u2-users-boun...@listserver.u2ug.org [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of George Gallen Sent: Wednesday, December 28, 2011 12:38 PM To: U2 Users List Subject: Re: [U2] MS-SQL Question It came back with unknown column error. I'll have to play with it again, it's possible I typed something wrong, But at least for now, it's working the other way I set it up. Thanks George -Original Message- From: u2-users-boun...@listserver.u2ug.org [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of David Jordan Sent: Wednesday, December 28, 2011 3:35 PM To: U2 Users List Subject: Re: [U2] MS-SQL Question You created PID as a synonym in the SELECT statement, you should be able to use it in the where clause. I am sure I have done that before in the past with SQL Server. Regards David Jordan -Original Message- From: u2-users-boun...@listserver.u2ug.org [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of George Gallen Sent: Thursday, 29 December 2011 7:09 AM To: U2 Users List Subject: Re: [U2] MS-SQL Question That didn't work because it is not a virtual column defined in the table layout. What I did was Created a variable in my program that contained the full string, and when I was creating the SQL String to pass to the server, I used the variable name instead. It worked in the sense, I didn't have to retype the string multiple times, but the SQL query that Was passed to the MSSQL machine did have it multiple times still, but at least it's more manageable From a programming standpoint, where I only have to make changes to one spot. George -Original Message- From: u2-users-boun...@listserver.u2ug.org [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of David Jordan Sent: Wednesday, December 28, 2011 3:04 PM To: U2 Users List Subject: Re: [U2] MS-SQL Question You should be able to just use PID in the where clause. David Jordan -Original Message- From: u2-users-boun...@listserver.u2ug.org [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of George Gallen Sent: Thursday, 29 December 2011 2:51 AM To: U2 Users Subject: [U2] MS-SQL Question I'm querying a sequel server , I have a column in one table that the data is in the form of X|Y|Z. I have the following in my SELECT: substring(colname ,charindex('|',colname)+1, charindex('|',colname, charindex('|',colname)+1) - charindex('|',colname) -1) as PID Is there anyway that I can then use the PID designation in a where clause, without having to retype the string again? I can't add a virtual column to the table , and I can't add a procedure either. ___ U2-Users mailing list U2-Users@listserver.u2ug.org http://listserver.u2ug.org/mailman/listinfo/u2-users ___ U2-Users mailing list U2-Users@listserver.u2ug.org http://listserver.u2ug.org/mailman/listinfo/u2-users ___ U2-Users mailing list U2-Users@listserver.u2ug.org http://listserver.u2ug.org/mailman/listinfo/u2-users ___ U2-Users mailing list U2-Users@listserver.u2ug.org http://listserver.u2ug.org/mailman/listinfo/u2-users ___ U2-Users mailing list U2-Users@listserver.u2ug.org http://listserver.u2ug.org/mailman/listinfo/u2-users ___ U2-Users mailing list U2-Users@listserver.u2ug.org http://listserver.u2ug.org/mailman/listinfo/u2-users
RE: [U2] unibasic select woes
Thank you. The 'word'... format is the answer to a question that had me banging my head yesterday. David Morelli, UIS/Datatel Team -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Andre Meij Sent: Wednesday, May 30, 2007 5:10 PM To: u2-users@listserver.u2ug.org Subject: RE: [U2] unibasic select woes Greg, Actually the following in saver: SELECT HRPER WITH EVAL OCONV(HRP.LAST.NAME,'MCU') LIKE 'SC'... (note the extra ' around the text) there are a few alphanumeric characters that are interpreted by SELECT and it will show you weird results when you are not expecting that. Regards, Andre -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Greg Schraiber Sent: maandag 30 april 2007 11:12 To: u2-users@listserver.u2ug.org; u2-users@listserver.u2ug.org Subject: RE: [U2] unibasic select woes Dave, Wyatt Karen, Thank you so much for the tips! Works like a charm! Thanks again, Greg At 12:45 PM 5/30/2007, Dave Davis wrote: In ECLTYPE u SELECT HRPER WITH EVAL OCONV(HRP.LAST.NAME,'MCU') LIKE SC... If you are currently in ECLTYPE p, you can put the word SELECT in lowercase to evaluate using the u parser. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Greg Schraiber Sent: Wednesday, May 30, 2007 1:28 PM To: u2-users@listserver.u2ug.org Subject: [U2] unibasic select woes How does one select alpha-numeric data from a unidata datafile using SELECT when the case of the text is not known? I have tried things like: SELECT HRPER WITH UPCASE(HRP.LAST.NAME) LIKE 'SC...' but all I get is a syntax error. Can someone tell me which function(s) can be used to facilitate this type of search? Any help is greatly appreciated! Thank you, Greg --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/
RE: [U2] Best practice for Sequential IDs using TRANSACTION START COMMIT/RO...
Is the audit trail allowed to keep a sorted list of rollback numbers? Open a process Request a number ... If rollback Insert the number into the Rollback List Else save record Close process Or if the goal is to consume all sequential numbers. Open a process Request the lowest number from the Rollback List If none then Request a number ... If rollback Insert the number into the Rollback List Else save record Close process When audited, show the completed items and the rollback list for a complete set of numbers. David Morelli, UIS/Datatel Team -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Brian Leach Sent: Tuesday, June 14, 2005 2:43 AM To: u2-users@listserver.u2ug.org Subject: RE: [U2] Best practice for Sequential IDs using TRANSACTION START COMMIT/RO... -Original Message- Subject: RE: [U2] Best practice for Sequential IDs using TRANSACTION START COMMIT/RO... Come on, people. A request was made for options... Okay so here goes: Write a service application (e.g. Windows service app) in Delphi that maintains a table of sequence numbers. Ensure you use a critical section (semaphore or Mutex wrapper) to make the incrementing routine thread safe. Use the Socket API or SOAP API to request the next number from the service. Have a second routine to place a number back on the stack in the event of a rollback. .. Seriously, if you are going to use transactions I would guess the only way to avoid maintaining the key for the duration of the transaction (to go back to the original post) would be to take it out of the transaction space e.g. outside the database and provide the sort of pop/push sequencing already discussed in this thread. But then that might be overcomplicating matters.. :-) Brian --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ --- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/