Function query (possible code suggestion)
wd
Posts: 25
Hi,
I read that you can create code snippets and place the code $CURSOR$ into the snippet to tell the cursor to start at that point after inserting the snippet.
Are there any other functions like $CURSOR$ that I maybe didn't see?
Something that would certainly help me would be to have the option of something like $DATE$ and $NAME$. Where $DATE$ is the system date when the snippet was inserted and $NAME$ the name of who inserted it.
These extra functions would allow me to make a code snippet for the header of my stored procedures.
It would then look something like this:
I would then have my name (from SQLPrompt Options) and the date entered automatically and then I could write a short description of what the procedure/function etc. will do.
What do you think? Good, bad, impossible?!
Regards
wd
I read that you can create code snippets and place the code $CURSOR$ into the snippet to tell the cursor to start at that point after inserting the snippet.
Are there any other functions like $CURSOR$ that I maybe didn't see?
Something that would certainly help me would be to have the option of something like $DATE$ and $NAME$. Where $DATE$ is the system date when the snippet was inserted and $NAME$ the name of who inserted it.
These extra functions would allow me to make a code snippet for the header of my stored procedures.
It would then look something like this:
/* Author : $NAME$ Date : $DATE$ Description : $CURSOR$ */
I would then have my name (from SQLPrompt Options) and the date entered automatically and then I could write a short description of what the procedure/function etc. will do.
What do you think? Good, bad, impossible?!
Regards
wd
Comments
That's a good idea and is something we might implement in the future. We have been thinking about enhancing snippet functionality further, but that probably won't happen until version 4.
Thanks,
Bart
Principal Consultant
bartread.com Ltd
I know that the 3.5 version is only just (pre)-released, but what is the roadmap for SQLPrompt? Will there be a few more minor releases in the coming months or are you working on the next major release?
Regards
wd
Thanks,
Bart
Principal Consultant
bartread.com Ltd
You may want to look at Visual Assiste X for VS 2005 , to see how they approach AutoText (ie Snippets)
You can add a snippet and include $Anything$ in the code , as you use the shortcut or select the snippet you are prompted to provide Anything , which is insetrted into the code wherever yo define $Anything$
Imagine creating a standard wrapped property by typing your variable once !
they are www.wholetomato.com
PS yes I am lazy any labour saving stuff for me !!
Cheers
Mike