Hello all,

I want to compare for now, two sets of arrays. I pull data from sql tables and then compare the two. I am using the
PHP Code:
array_diff(); 
function to compare the two arrays, but its showing it as a empty array. Is that because I am not telling it which demensions to look at? Like
PHP Code:
array_diff($array1[5], $array2[5]); 
?

Here is the current code:
PHP Code:
<?php
//Opens a connection to the Warta Database
    
try {
        
$wrd1 =  new PDO('mysql:host=localhost; dbname=*****''******''*****');
            
$wrd1->setAttribute(PDO::ATTR_ERRMODEPDO::ERRMODE_EXCEPTION);
                
$cale $wrd1->prepare(
                
"SELECT
                start,
                end,
                repeat_freq,
                repeat_int,
                repeat_end,
                allDay,
                category_id,
                description,
                link,
                venue,
                address,
                city,
                state,
                zip,
                country,
                contact,
                contact_info,
                access,
                rsvp
                FROM
                wp_aec_event
                "
);
                    
//executes SQL statement
                    
$cale->execute();
                        
//Set into array
                        
$result $cale->fetchAll(PDO::FETCH_ASSOC);
                        
print_r($result);
                        echo(
"\n");
    

    
            
//Opens a connection to the 1-sza Database
            
try {
                
$wrd2 = new PDO('mysql:host=localhost; dbname=*****''*******''**');
                    
$wrd2->setAttribute(PDO::ATTR_ERRMODEPDO::ERRMODE_EXCEPTION);
                        
$cale1 $wrd2->prepare(
                        
"SELECT
                        start,
                        end,
                        repeat_freq,
                        repeat_int,
                        repeat_end,
                        allDay,
                        category_id,
                        description,
                        link,
                        venue,
                        address,
                        city,
                        state,
                        zip,
                        country,
                        contact,
                        contact_info,
                        access,
                        rsvp
                        FROM
                        wp_aec_event
                        "
);
                            
//executes SQL statement
                            
$cale1->execute();
                                
//set into array
                                
$result1=$cale1->fetchALL(PDO::FETCH_ASSOC);
                                
print_r($result1);
                                echo(
"\n");
                                
                                
//testing out php array compare
                                
$compare array_diff($result$result1);
                                
print_r($compare);
            }
            catch (
PDOException $ex) {
            
$msg $ex->errorInfo;
            
error_log(var_export($msgtrue));
            die(
"<p>Sorry, there was a unrecoverable database error.  Debug data has been logged.</p>");
            }

    }            
    catch (
PDOException $ex) {
    
$msg $ex->errorInfo;
    
error_log(var_export($msgtrue));
    die(
"<p>Sorry, there was a unrecoverable database error.  Debug data has been logged.</p>");
    };
?>