SoftTree Technologies SoftTree Technologies
Technical Support Forums
RegisterSearchFAQMemberlistUsergroupsLog in
EXEC formatting

 
Reply to topic    SoftTree Technologies Forum Index » SQL Assistant View previous topic
View next topic
EXEC formatting
Author Message
ekgurney



Joined: 08 May 2009
Posts: 3
Country: United States

Post EXEC formatting Reply with quote
I was playing around with formatting EXEC statements but couldn't get it to look like I'd like.

I'd like the statement to be formatted as follows:

EXEC ProcedureName
@Param1 = 1,
@Param2 = 2,
...

Is there a way to do this?

Thanks, Eric
Fri May 08, 2009 9:20 am View user's profile Send private message
SysOp
Site Admin


Joined: 26 Nov 2006
Posts: 7847

Post Reply with quote
Set formatting rule for EXEC to the following

Code:
EXEC
    ...,
    ...

Fri May 08, 2009 9:48 am View user's profile Send private message
ekgurney



Joined: 08 May 2009
Posts: 3
Country: United States

Post Reply with quote
That gives me

EXEC
ProcedureName @Param1 = 1,
@Param2 = 2

I'd really like the procedure name on the same line as the exec statement, and parameters indented below, 1 per line.
i.e.

EXEC ProcedureName
@Param1 = 1,
@Param2 = 2

Thanks,
Eric
Fri May 08, 2009 9:55 am View user's profile Send private message
SysOp
Site Admin


Joined: 26 Nov 2006
Posts: 7847

Post Reply with quote
I'm unable to reproduce your case. May be you customized some other style-level formatting rules that conflict with what you want for this specific statement-level rule. Please start with the default configuration and modify just the EXEC rule.
Fri May 08, 2009 12:38 pm View user's profile Send private message
ekgurney



Joined: 08 May 2009
Posts: 3
Country: United States

Post Reply with quote
I just installed the program, modified the exec statement with the code posted in the previous post and that was the result.

If I start w/
EXEC ProcedureName @Param1 = 1, @Param2 = 2
I get the result above

if I start w/
EXEC ProcedureName
@Param1 = 1, @Param2 = 2

I get:
EXEC
ProcedureName,
@Param1 = 1,
@Param2 = 2
Fri May 08, 2009 12:50 pm View user's profile Send private message
SysOp
Site Admin


Joined: 26 Nov 2006
Posts: 7847

Post Reply with quote
I'm pretty sure I responded to this yesterday. Not sure what has happened, but my response is not here.

Anyway, here is what I get using your examples and the default setup
(the appearance may slightly differ when this code is displayed on the web page)

Code:
/************************************************************
 * Code formatted by SoftTree SQL Assistant © v4.6.12
 * Time: 5/9/2009 12:40:14 PM
 ************************************************************/

EXEC ProcedureName @Param1 = 1,
      @Param2 = 2

EXEC ProcedureName
      @Param1 = 1,
      @Param2 = 2


customized EXEC pattern
Code:

/************************************************************
 * Code formatted by SoftTree SQL Assistant © v4.6.12
 * Time: 5/9/2009 12:38:32 PM
 ************************************************************/

EXEC
     ProcedureName @Param1 = 1,
     @Param2 = 2

EXEC
     ProcedureName
     @Param1 = 1,
     @Param2 = 2



It seems to me that the default formatting does what you need, if you start with
EXEC ProcedureName
@Param1 = 1, @Param2 = 2

So far I couldn't find any other way to handle that.
Sat May 09, 2009 12:55 pm View user's profile Send private message
Display posts from previous:    
Reply to topic    SoftTree Technologies Forum Index » SQL Assistant All times are GMT - 4 Hours
Page 1 of 1

 
Jump to: 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


 

 

Powered by phpBB © 2001, 2005 phpBB Group
Design by Freestyle XL / Flowers Online.