Using logged user detail from one table ,then use another table to link more details for same user ?

Table 'user' fields:
UserID* (Primary Key)
Address
FirstName
LastName
Email
UserName
Password
UserLevel
RegDate
Table 'transaction' fields:
transactionID* (Primary Key)
MonthID
UserID (Foreign Key)
UserName
transactionDate
transactionType
transactionAmount
OpeningBalance
Balance
Desired output table (for the logged user):
transactionDate
transactionType
transactionAmount
OpeningBalance
Balance
My advance recordset details is like this :
<?php
if (!function_exists("GetSQLValueString")) {
function GetSQLValueString($theValue, $theType, $theDefinedValue = "", $theNotDefinedValue = "")
if (PHP_VERSION < 6) {
$theValue = get_magic_quotes_gpc() ? stripslashes($theValue) : $theValue;
$theValue = function_exists("mysql_real_escape_string") ? mysql_real_escape_string($theValue) : mysql_escape_string($theValue);
switch ($theType) {
case "text":
$theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
break;
case "long":
case "int":
$theValue = ($theValue != "") ? intval($theValue) : "NULL";
break;
case "double":
$theValue = ($theValue != "") ? doubleval($theValue) : "NULL";
break;
case "date":
$theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
break;
case "defined":
$theValue = ($theValue != "") ? $theDefinedValue : $theNotDefinedValue;
break;
return $theValue;
mysql_select_db($database_bankusers, $bankusers);
$query_Recordset1 = "SELECT transactions.UserName, transactions.transactionDate, transactions.transactionType, transactions.transactionAmount, transactions.OpeningBalance, transactions.EndBalance, users.FirstName, transactions.transactionID FROM transactions, users WHERE users.UserName = transactions.UserName ORDER BY transactions.UserName, transactions.transactionID DESC";
$Recordset1 = mysql_query($query_Recordset1, $bankusers) or die(mysql_error());
$row_Recordset1 = mysql_fetch_assoc($Recordset1);
$totalRows_Recordset1 = mysql_num_rows($Recordset1);
?>
This enables me to pull all the records from both tables but not specific to the logged user.
This is my problem. I would like the record to be pull is for the right user.
I am not sure if the the problem is to do with Session variable MM_UserName as I have no idea how to include it in the advanced recordset box but i am not sure there is no missing session start on this page.  Your help or suggestion will be much appreciated.

I am getting this error on the browser :
You have an error in your SQL syntax; check the manual that corresponds  to your MySQL server version for the right syntax to use near 'ORDER BY  transactions.UserName, transactions.transactionID DESC' at line 1
Here is my full code :
<?php require_once('Connections/bankusers.php'); ?>
<?php @session_start(); ?>
<?php
if (!isset($_SESSION)) {
  session_start();
$MM_authorizedUsers = "";
$MM_donotCheckaccess = "true";
// *** Restrict Access To Page: Grant or deny access to this page
function isAuthorized($strUsers, $strGroups, $UserName, $UserGroup) {
  // For security, start by assuming the visitor is NOT authorized.
  $isValid = False;
  // When a visitor has logged into this site, the Session variable MM_Username set equal to their username.
  // Therefore, we know that a user is NOT logged in if that Session variable is blank.
  if (!empty($UserName)) {
    // Besides being logged in, you may restrict access to only certain users based on an ID established when they login.
    // Parse the strings into arrays.
    $arrUsers = Explode(",", $strUsers);
    $arrGroups = Explode(",", $strGroups);
    if (in_array($UserName, $arrUsers)) {
      $isValid = true;
    // Or, you may restrict access to only certain users based on their username.
    if (in_array($UserGroup, $arrGroups)) {
      $isValid = true;
    if (($strUsers == "") && true) {
      $isValid = true;
  return $isValid;
$MM_restrictGoTo = "loginuser.php";
if (!((isset($_SESSION['MM_Username'])) && (isAuthorized("",$MM_authorizedUsers, $_SESSION['MM_Username'], $_SESSION['MM_UserGroup'])))) {  
  $MM_qsChar = "?";
  $MM_referrer = $_SERVER['PHP_SELF'];
  if (strpos($MM_restrictGoTo, "?")) $MM_qsChar = "&";
  if (isset($_SERVER['QUERY_STRING']) && strlen($_SERVER['QUERY_STRING']) > 0)
  $MM_referrer .= "?" . $_SERVER['QUERY_STRING'];
  $MM_restrictGoTo = $MM_restrictGoTo. $MM_qsChar . "accesscheck=" . urlencode($MM_referrer);
  header("Location: ". $MM_restrictGoTo);
  exit;
?>
<?php
if (!function_exists("GetSQLValueString")) {
function GetSQLValueString($theValue, $theType, $theDefinedValue = "", $theNotDefinedValue = "")
  if (PHP_VERSION < 6) {
    $theValue = get_magic_quotes_gpc() ? stripslashes($theValue) : $theValue;
  $theValue = function_exists("mysql_real_escape_string") ? mysql_real_escape_string($theValue) : mysql_escape_string($theValue);
  switch ($theType) {
    case "text":
      $theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
      break;   
    case "long":
    case "int":
      $theValue = ($theValue != "") ? intval($theValue) : "NULL";
      break;
    case "double":
      $theValue = ($theValue != "") ? doubleval($theValue) : "NULL";
      break;
    case "date":
      $theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
      break;
    case "defined":
      $theValue = ($theValue != "") ? $theDefinedValue : $theNotDefinedValue;
      break;
  return $theValue;
mysql_select_db($database_bankusers, $bankusers);
$query_Recordset1 = "SELECT transactions.UserName, transactions.transactionDate, transactions.transactionType, transactions.transactionAmount, transactions.OpeningBalance, transactions.EndBalance, users.FirstName, transactions.transactionID FROM transactions, users WHERE users.UserName = transactions.UserName AND users.UserName = $MM_UserName ORDER BY transactions.UserName, transactions.transactionID DESC";
$Recordset1 = mysql_query($query_Recordset1, $bankusers) or die(mysql_error());
$row_Recordset1 = mysql_fetch_assoc($Recordset1);
$totalRows_Recordset1 = mysql_num_rows($Recordset1);
?>
<!DOCTYPE HTML>
<html>
<head>
  <title>user summary</title>
  <meta name="description" content="website description" />
  <meta name="keywords" content="website keywords, website keywords" />
  <meta http-equiv="content-type" content="text/html; charset=windows-1252" />
  <link rel="stylesheet" type="text/css" href="style/style.css" title="style" />
</head>
<body>
  <div id="main">
    <div id="header">
      <div id="logo">
        <div id="logo_text">
          <!-- class="logo_colour", allows you to change the colour of the text -->
          <h1><a href="index.php">ModelOnline<span class="logo_colour">Bank</span></a></h1>
          <h2>Your. Bank. On. Demand.</h2>
        </div>
      </div>
      <div id="menubar">
        <ul id="menu">
          <!-- put class="selected" in the li tag for the selected page - to highlight which page you're on -->
          <li class="selected"><a href="indexoriginal.php">Home</a></li>
          <li><a href="register.php">REGISTER</a></li>
          <li><a href="login.php">lOGIN</a></li>
          <li><a href="aboutus.php">ABOUT US</a></li>
          <li><a href="contactus.php">Contact Us</a></li>
          <li><a href="cookies.php">Cookies</a></li>
          <li><a href="accessibility.php">Accessibility</a></li>
          <li><a href="security.php">Security</a></li>
        </ul>
      </div>
    </div> <div align="center" class="bankservices"><a href="http://www.modelonlinebank.com/bankproducts.php#one">Current Accounts</a> | <a href="http://www.modelonlinebank.com/bankproducts.php#two">Savings Accounts</a> | <a href="http://www.modelonlinebank.com/bankproducts.php#three">Mortgages</a> | <a href="http://www.modelonlinebank.com/bankproducts.php#four">Insurance</a> | <a href="http://www.modelonlinebank.com/bankproducts.php#five">Credit Cards</a> | <a href="http://www.modelonlinebank.com/bankproducts.php#six">Investments</a></div>
    <div id="site_content">
      <div class="sidebar">
        <!-- insert your sidebar items here -->
        <<h3>Latest News</h3>
        <h4>Personal Banking</h4>
        <h5>January 1st, 2014</h5>
        <p>Current Accounts,Saving Accounts,Range of Credit And Debit cards to suit all your needs. We have your interest in mine.<br />
        <a href="#">Read more</a></p>
<p></p>
        <h4>Corporate Banking</h4>
        <h5>February 5th, 2014</h5>
        <p>We help you achieve your goals by providing numerous funding options.Provide Risk management of your finances and look for strategic and finance options to promote business.<br /><a href="#">Read more</a></p>
        <h3>Useful Links</h3>
        <ul>
          <li><a href="#">Credit card</a></li>
          <li><a href="#">Debit card</a></li>
          <li><a href="#">Loans</a></li>
          <li><a href="#">Insurance</a></li>
        </ul>
        <h3>Search</h3>
        <form method="post" action="#" id="search_form">
          <p>
            <input class="search" type="text" name="search_field" value="Enter keywords....." />
            <input name="search" type="image" style="border: 0; margin: 0 0 -9px 5px;" src="style/search.png" alt="Search" title="Search" />
          </p>
        </form>
      </div>
      <div id="content">
        <!-- insert the page content here -->
        <h1>Welcome <?php echo $row_Recordset1['FirstName']; ?>,to your control panel.</h1>
        <p><a href="logout.php">Logout</a> </p>
        <p>Summary of Last Transaction on our system:
         </p>
        <form name="form1" method="post" action="">
          <table border="0">
            <tr>
              <th bgcolor="#D6D6D6">Date</th>
              <th bgcolor="#D6D6D6">Transaction Type</th>
              <th bgcolor="#D6D6D6">Transaction Amount</th>
              <th bgcolor="#D6D6D6">Previous Balance</th>
              <th bgcolor="#D6D6D6">Balance</th>
            </tr>
            <tr>
              <td><?php echo $row_Recordset1['transactionDate']; ?></td>
              <td><?php echo $row_Recordset1['transactionType']; ?></td>
              <td><?php echo $row_Recordset1['transactionAmount']; ?></td>
              <td><?php echo $row_Recordset1['OpeningBalance']; ?></td>
              <td><?php echo $row_Recordset1['EndBalance']; ?></td>
            </tr>
          </table>
        </form>
<p><a href="monthly.php">View Monthly Statement</a></p>
        <p><a href="paysomeone.php">Pay Someone</a></p>
        <p><a href="standingorder.php">Standing Orders</a></p>
        <p><a href="directdebit.php">Direct Debits</a></p>
        <p><a href="contactus.php">Customer Services</a></p>
        <p> </p>
        <p> </p>
</div>
    </div>
    <div id="content_footer"></div>
    <div id="footer">
      Copyright &copy; Sundeep gurroby BCS PGD<a href="http://www.html5webtemplates.co.uk"></a>
    </div>
  </div>
</body>
</html>
<?php
mysql_free_result($Recordset1);
?>

Similar Messages

  • Mass user movement from one org. unit to another in SRM org. structure

    Hi,
    Is there any way by which i can move mass users from one organisational unit to another in SRM org. structure..
    there is a thread available in SDN but it is not conclusive. it talks abt using a FM: BBP_USER_CHANGE_ORG
    BR
    Bharat M

    Bharat-
    I am assuming that your requirement is to move mass users from One Org node to another. Ex One Plant Org node to Another plant Org node.
    If my assumption is correct then, please follow the below steps.
    1) Go in to the change mode of Org Plan using T-code PPOMA_BBP
    2) Using shift key, select all the users that you need to move.
    3) Drag and Drop the selected users to the desired Org node.
    If the user IDs are not in sequence then you can use Ctrl key to select the relevant user ID.
    Let me know if you have any questions.
    If the answer is helpful, please reward points.
    Regards,
    Upendra.

  • Migrate/Copy Contract details from one company code to another

    Hi,
    We are planning to migrate/copy some contracts from  one company code to another.
    I've read a related post regarding this, but I would like to know more about the steps on how to do it and if it is possible also to copy the conracts' present contract numbers and other contract details  to the new company code.
    Thank you so much.

    Hi Rachelle,
    you can use BAPIs in RE-FX.
    1. BAPI_RE_CN_GET_DETAIL to read the contract data
    2. Change the data according to your requirements
         For example it may be necessary to change the adjustment parameters ..
    3. BAPI_RE_CN_CREATE to create the contracts in the new company code
    If you want to have the same contract number you would have to switch to external numbering in the new company code.
    Regards, Franz

  • Can I copy my apps/user settings from one drive/OS to another?

    I have one drive of my system with 10.3.9, that I've been using for quite awhile, with all my apps, preferences, registrations etc.
    I just installed a clean install of 10.4.3 on another drive.
    Is there away to clone/copy all my user settings from the 10.3.9 drive to the 10.4.3 drive, so that it behaves the same way?
    I didn't want to user the "transfer user settings" when I installed 10.4, because I need to keep the 10.3.9 system exactly as is.

    Just erase the hard drive first. Here's the basic cloning process using Disk Utility:
    1. Open Disk Utility from the Utilities folder.
    2. Select the startup volume from the left side list.
    3. Click on the Restore tab in the DU main window.
    4. Drag the startup volume to the Source entry field.
    5. Select the backup volume from the leftside list and drag it to the Destination entry field.
    6. Check the box to Erase Destination.
    7. Double-check you got it right, then click on the Restore button.
    If you prefer to keep your Panther system, then clone it to the new drive and update the new drive to Tiger. If you want both drives to have Tiger installed, then upgrade the Panther system to Tiger, then clone it to the new drive.
    If you'd rather see how it goes using Migration Assistant, then by all means give it a try. Worst thing that can happen is you end up doing it my way. If Migration Assistant works properly you'll save some time and effort.

  • Is it possible to move users/licenses from one team/account to another if I am administrator for both?

    My company ended up with two Adobe CC teams/accounts as there were two groups in the company who needed it simultaneously.  I am admin for both teams, and what I'd like to do is simply merge them into one.  I've not found any way of doing this myself, I'm not sure if it's even possible.

    assign a new team member http://forums.adobe.com/thread/1460939?tstart=0 may help or
    Creative Cloud Help | Manage your Creative Cloud for teams membership

  • Importing User settings from one CC user into another

    Hi There,
    I want to import user settings from one account, then use those as a base to setup user setting for another. IE I want to use my settings from work [which I did not pay for] and use that as a starting point for my personal user account at my home office [which I did pay for].
    I'm concerned about messing up my work settings + at home I'm on a laptop, not a 2 display tower.
    Specificaly, its the custom keyboard, sequence and output, and loging colums/metadata display settings that I'd love not to have to setup from scratch, again.
    Also, I have co workers who prefer my settings and I'd like to share these with them- but don't want them to be signed in as me, and messing me up accidentaly.
    Many Thanks
    David

    OK so this does not work. I'm running CC, on OSX 10.8.3.
    For those that don't know, in order to reveal the library folder in OSX 10.7+, you need to either enter this into terminal:
    Permanent Reveal:
    chflags nohidden ~/Library/
    Permanent Hide:
    chflags hidden ~/Library
    Or hold down option key + finder/go, for temporary reveal.
    So after doing this, and coying over the directories Jax mentioned [+ '7.0' folders, as I'm in CC], I'm still not getting the keyboard mappings, just the defaults.
    I've just synced with my work account, and brought up another issue: My scratch disks and media paths are all different on my home office, and I don't want to have to reset those everytime I switch from one location to another.
    If I could get what Jax sudgested to work, that would be an exelent work arround for this situation. Otherwise its a feature request for managing syncing between multiple accounts...
    Thanks again Jax for tyring to help

  • Migrating User Settings from one local user to another

    I have an iMac running 10.5.4 with some issues (Parallels hanging at random moments). One of the tests I did to troubleshoot it was create a new user profile, and run the same (shared) Parallels machine as that new user, which seemed to fix the problem.
    I would like to being gradually copying over user preferences & data from the old account to the new one, bit by bit, so that if one of those items is causing the problem with Parallels, we can catch it.
    Is there a preferred way to copy or move over user settings from one local account to another on the same Mac? Basic files like Documents, etc. I know I can just drop into the Shared folder, but I am more concerned with Preferences, apps that use databases to point to files (like iTunes), and permissions.
    Thank you!

    V.K. (and anyone else who cares) - I finally figured out the problem: the mount point for the volume containing my Home directory ("Data") was changed by the system, but only on my primary startup volume ("System")... so when I booted from SystemClone everything was okay... but when I booted from System I had no account, no preferences, no nothing. Because the visible label on the volume containing Home was correct (even though the actual name - the mount point - was different), regardless of whether I booted from System or SystemClone, I assumed everything here was in order.
    Bottom line: when booting from System, my Data volume's visible label read "Data" .. the path to Home directory under the account's advanced settings read "/volumes/data/directoryName" ... but my Data volume's mount point read "Data 1" .. when booting from SystemClone, my Data volume's visible label read "Data" .. the path to Home directory under the account's advanced settings read "/volumes/data/directoryName" ... and my Data volume's mount point read "Data" (so everything worked).
    Lesson learned: don't assume.. check the mount point reference using Disk Utility.
    Approach validated: if I didn't have a bootable SystemClone, I would have never been able to figure this out, and repair everything without rebuilding.

  • Transaction data from one cost center to another cost center

    Hi All
    Can any one tel me how to move the Transaction data from one cost center to another cost center .
    My scenario is basically : Users posted for  company code 1003 for Cost center S00570 for the period 01.04.2007  to 30.11.2007 but it has to go to company code 1000  instead of 1003  for the same Cost center .S00570 .
    What we have done is that we have changed the cost center from 01.12.2007 on words to the correct company code 1000 and now all postings are going to the right company code ie
    to company code 1000.
    Now the problem is how to bring back the old historical data posted  from 01.04.2007 to 30.11.2007  to wrong company code the 1003 to correct company code  1000 .
    Is there a way to bring back the historical data which has posted to wrong company code .
    Thanks in Advance .
    Any help highly appreciated and points are assigned .
    Cheers
    Ravindra.

    Ravindra
    Once you have changed the company code in the master data, then the entries with respect to the different company code cannot be transferred. Please follow the process below and let me know if it works.
    1. Revert the cost center master data to the original company code.
    2. Repost the line items from this cost center to another cost center. Use tcode KB61. The cost center you will be reposting will be a routing cost center (say XXXXX).
    3. Once all the line items have been reposted, change the master data of the cost center to the correct company code.
    4. Again repost the costs from the routing cost center(XXXXX) to the correct cost center. You should have all the line items to the correct cost center now.
    For more on reposting refer the link below:
    http://help.sap.com/SAPHELP_470/Helpdata/EN/27/c98a46db7011d1a5400060086e9494/frameset.htm
    Let me know if it worked.
    Karthik Coneru

  • How to migrate mail system from one hard drive to another under 10.6.8 in a macpro

    how do you migrate mail settings, calendar information, etc from one hard drive to another under 10.6.8 in the same computer?  Migration Application does not show this option.  It shows from an old computer to another, etc.

    You have to install the OS onto the new HD and then use the setup assistant on first boot to migrate from the original HD.
    27" i7 iMac (Mid 2011) refurb, OS X Yo (10.10.1), Mavs, ML & SL, G4 450 MP w/10.5 & 9.2.2

  • Free Goods from One Material Group to Another Material Group

    Salute Masters!! 
    I need your valuble suggestion, please provide.
    I need to configure Free Goods of Material Group to Material Group.
    User want:
    1) Free Goods from one Material Group to another Material Group, like F010 to F040
    2) User should have option to change from one Material Group to Other Material Group, which He / She want, like F010 or F020, F030, F040 any one of them.
    Suppose;
    Line Item Material Belongs to One Group Quantity in Gallons Free Goods from Any Material Group Quantity in Gallons
          1            A                                              3                                    F010                                             4
          2            B                                              3                                     F020
          3            C                                              4                                     F040
    Any No. of Line Item Any No. of Material
                                       from One Group      Total 10                   From Any Material Group
    (Comprising of 3-4 Different Material from 1 Group, they should be able to choose/provide Free Goods from other Material Group)
    3) While creating Sales Order what Quantity (Gallons/No./Ltr) to be put?
    How I can configure this scenario?
    Please suggest, is it  possible through KEY COMBINATION?
    Rgds.
    Srivastav
    +91 7829755109
    Skype ID: sanjai.srivastav1

    Hi,
    if you want to give free goods from other group it can be possible only for EXCLUSIVE free good type
    In exclusive free goods, a material different from the orignal material can be specified as the free goods.
    Example: A customer who buys 200 crates of beer, gets 5 boxes of glasses free.
    In VBN1 >> Exclusive
    See column ADD FREE MATERIAL
    While creating Sales Order what Quantity (Gallons/No./Ltr) to be put?
    Maintain alternative units in material master >> Additional data >> Material master,BUT it is only main item
    Those item u want to give free that items unit is derived from free goods condition record and it CANNOT be change in order

  • Moving the Individual Protection group from one SAN Volume to another SAN Volume

    Hi Professionals
    Dudes !!! There is no much information about migratedatasourcedatafromdpm.ps1
    script on the technet. My question is that I need to move Individual Protection group in an orderly manner from one SAN Storage to Another. I have more than 30 protection groups. I want to move individually 2 to 3 protection groups at one time from
    Old SAN Storage to New SAN storage. Is it possible that I mention  protection group individually and move each protection group bit-by-bit to the new SAN Storage. 

    Hi,
    you can use this GUI Option, to move a whole Disk.
    in the next Version, hopefully published this Week, you can select a whole Protectiongroup to move
    http://gallery.technet.microsoft.com/Migrate-DPM-Disk-or-dea8d4e9
    Seidl Michael | http://www.techguy.at |
    twitter.com/techguyat | facebook.com/techguyat

  • Can I transfer purchases from one itunes account to another, if so how

    Can I transfer purchases from one itunes account to another, if so how

    This forum is for questions from those managing sites on iTunes U, Apple's service for colleges and universities to post educational material in the iTunes Store. You'll be most likely to get help with this issue if you ask in the general iTunes forums.
    Answering quickly, though, if you mean you want to transfer a purchase from one iTunes Store account to another, you cannot.
    Regards.

  • How do you transfer contacts and other info from one gmail address to another?

    Somebody screwed up my gmail so I created another account which does synch with my android phone which the other does not. But I lost all my contacts from the phone. The contacts still exist but they are on the old gmail account which does not synch with my cellphone. How do I transfer my addresses and phone numbers from one gmail address to another?

    That is a question for Gmail support.
    https://support.google.com/mail/?hl=en

  • How to transfer purchases from one Apple ID to another?

    Hey guys,
    I'm planning on creating a new Apple ID due to an email address change, but am worried that doing so will prevent me from reinstalling any purchases I have made with my old Apple ID.
    Does anyone know a way to transfer my purchases from one Apple ID to another permanently?
    Thanks in advance for any advice,
    Dan

    It is not possible to merge two iTunes accounts.
    Do yourself a favor, do not create a new iTunes account, simply update the account information for the one you already have.

  • Can you register iPhone on one computer, then use the library from another?

    My iTunes store doesn't work on my computer (ive tried to fix it - i think it's a virus on my computer), so what i thought i'd do is register my iPhone through my dads computer, then carry on using the iTunes library from my computer.
    Is it possible to register iPhone on one computer, then use the iTunes library from another computer?

    .

  • [Forum FAQ] How to configure a Data Driven Subscription which get multi-value parameters from one column of a database table?

    Introduction
    In SQL Server Reporting Services, we can define a mapping between the fields that are returned in the query to specific delivery options and to report parameters in a data-driven subscription.
    For a report with a parameter (such as YEAR) that allow multiple values, when creating a data-driven subscription, how can we pass a record like below to show correct data (data for year 2012, 2013 and 2014).
    EmailAddress                             Parameter                      
    Comment
    [email protected]              2012,2013,2014               NULL
    In this article, I will demonstrate how to configure a Data Driven Subscription which get multi-value parameters from one column of a database table
    Workaround
    Generally, if we pass the “Parameter” column to report directly in the step 5 when creating data-driven subscription.
    The value “2012,2013,2014” will be regarded as a single value, Reporting Services will use “2012,2013,2014” to filter data. However, there are no any records that YEAR filed equal to “2012,2013,2014”, and we will get an error when the subscription executed
    on the log. (C:\Program Files\Microsoft SQL Server\MSRS10_50.MSSQLSERVER\Reporting Services\LogFiles)
    Microsoft.ReportingServices.Diagnostics.Utilities.InvalidReportParameterException: Default value or value provided for the report parameter 'Name' is not a valid value.
    This means that there is no such a value on parameter’s available value list, this is an invalid parameter value. If we change the parameter records like below.
    EmailAddress                        Parameter             Comment
    [email protected]         2012                     NULL
    [email protected]         2013                     NULL
    [email protected]         2014                     NULL
    In this case, Reporting Services will generate 3 reports for one data-driven subscription. Each report for only one year which cannot fit the requirement obviously.
    Currently, there is no a solution to solve this issue. The workaround for it is that create two report, one is used for view report for end users, another one is used for create data-driven subscription.
    On the report that used create data-driven subscription, uncheck “Allow multiple values” option for the parameter, do not specify and available values and default values for this parameter. Then change the Filter
    From
    Expression:[ParameterName]
    Operator   :In
    Value         :[@ParameterName]
    To
    Expression:[ParameterName]
    Operator   :In
    Value         :Split(Parameters!ParameterName.Value,",")
    In this case, we can specify a value like "2012,2013,2014" from database to the data-driven subscription.
    Applies to
    Microsoft SQL Server 2005
    Microsoft SQL Server 2008
    Microsoft SQL Server 2008 R2
    Microsoft SQL Server 2012
    Please click to vote if the post helps you. This can be beneficial to other community members reading the thread.

    For every Auftrag, there are multiple Position entries.
    Rest of the blocks don't seems to have any relation.
    So you can check this code to see how internal table lt_str is built whose first 3 fields have data contained in Auftrag, and next 3 fields have Position data. The structure is flat, assuming that every Position record is related to preceding Auftrag.
    Try out this snippet.
    DATA lt_data TYPE TABLE OF string.
    DATA lv_data TYPE string.
    CALL METHOD cl_gui_frontend_services=>gui_upload
      EXPORTING
        filename = 'C:\temp\test.txt'
      CHANGING
        data_tab = lt_data
      EXCEPTIONS
        OTHERS   = 19.
    CHECK sy-subrc EQ 0.
    TYPES:
    BEGIN OF ty_str,
      a1 TYPE string,
      a2 TYPE string,
      a3 TYPE string,
      p1 TYPE string,
      p2 TYPE string,
      p3 TYPE string,
    END OF ty_str.
    DATA: lt_str TYPE TABLE OF ty_str,
          ls_str TYPE ty_str,
          lv_block TYPE string,
          lv_flag TYPE boolean.
    LOOP AT lt_data INTO lv_data.
      CASE lv_data.
        WHEN '[Version]' OR '[StdSatz]' OR '[Arbeitstag]' OR '[Pecunia]'
             OR '[Mita]' OR '[Kunde]' OR '[Auftrag]' OR '[Position]'.
          lv_block = lv_data.
          lv_flag = abap_false.
        WHEN OTHERS.
          lv_flag = abap_true.
      ENDCASE.
      CHECK lv_flag EQ abap_true.
      CASE lv_block.
        WHEN '[Auftrag]'.
          SPLIT lv_data AT ';' INTO ls_str-a1 ls_str-a2 ls_str-a3.
        WHEN '[Position]'.
          SPLIT lv_data AT ';' INTO ls_str-p1 ls_str-p2 ls_str-p3.
          APPEND ls_str TO lt_str.
      ENDCASE.
    ENDLOOP.

Maybe you are looking for