i have a code like this

```
sprintf(data, "%d|Hello world|Ticket|Offset=44|msgId=1050        %d|%d|%d", r+1,header->m_msgId,header->m_sequence,header->m_offset);

```

where data is a char array of size 100 and header is a structure variable.

now after writing this whole to data using sprintf i want to break this whole data into two and then copy it into two new variable 

```
char var1[100],var2[100];

```

This can be done with sscanf but waht i want is that in var1 i want only the part till 

```
%d|Hello world|Ticket|Offset=44|msgId=1050

```

whereas in var2 i want the part after that ie

```
%d|%d|%d

```

.one way is to do %[^\t} and so on but in this case the value inside var1 is correct but inside var2 tab space is also inserted along with some weird character at the end of three %d.i cant change the format of data that has to be entered in my variable **data**.
please help me out that how can i do this using help of sscanf.thanks for any help in advance